Further workarounds for the broken string marshalling in xmlrpclib. Regardless
authoremellor@leeni.uk.xensource.com <emellor@leeni.uk.xensource.com>
Wed, 5 Apr 2006 23:59:06 +0000 (00:59 +0100)
committeremellor@leeni.uk.xensource.com <emellor@leeni.uk.xensource.com>
Wed, 5 Apr 2006 23:59:06 +0000 (00:59 +0100)
commitd220279c332247edc78db398b22fdc4a25f556d4
tree3a3659611d6e4a418855c72f5ae2bb2335c0f55f
parentc0693d2c6e8800a274b280220254c42eafd2aecd
Further workarounds for the broken string marshalling in xmlrpclib.  Regardless
of the encoding used, one still may not include non-printable characters in an
XML document.  When a dmesg contains a ^D character, something seen on one of
our test machines, an invalid XML document is generated.

Use a trick by David Mertz to work around this -- escape the string using
Python's repr function.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
tools/python/xen/util/xmlrpclib2.py